EvenMore 0.60

A freeware textviewer for the Amiga

EvenMore �1996-2002 Chris Perver
ReqTools  �1991-1994 Nico Fran�ois,
                 �1995-1998 Magnus Holmgren


    Contents

Disclaimer
Introduction
System requirements
Installation
Features
Getting started
Programming EvenMore
Contacting
Credits

    DISCLAIMER

This archive can be distributed by commercial or private companies, profit making or otherwise, as long as the following rules are applied.

1) The contents of this archive must remain intact and unaltered. This archive is permitted to be distributed so long as all the files are included and are not malformed, edited, changed or modified in any way, by accident or intent. 
2) The version distributed must be the latest release. (Check on aminet, the EvenMore homepage or email me) 
3) This archive may be distributed and advertised by public domain libraries, as long as no profit is made on the program, and the price is no higher than the cost of a disk, copying and distribution costs. This is freeware! You can't charge people any money for it!

I HEREBY DISCLAIM ALL RESPONSIBILTIES FOR THE USE OR MIS-USE OF THIS SOFTWARE.

THIS SOFTWARE IS PROVIDED 'AS IS', AND IS SUBJECT TO CHANGE WITHOUT FURTHER NOTICE. THERE ARE NO GUARANTEES THAT THIS SOFTWARE WORKS, HAS NO BUGS, AND THAT IT WILL NOT HARM ANY OF YOUR EQUIPMENT OR SOFTWARE ETC. BY USING THIS SOFTWARE, YOU AGREE THAT ANY DAMAGES INFLICTED ARE THE TOTAL RESPOSIBILITY OF NONE OTHER INDIVIDUALS, OR GROUPS, BUT YOURSELF, AND YOU MUST MEET THE EXPENSES TO COVER THE DAMAGES. THIS AUTHOR WILL NOT BE HELD RESPONSIBLE FOR ANY DAMAGES THAT MAY BE CAUSED, EITHER DIRECTLY OR INDIRECTLY BY USING THIS SOFTWARE. BEFORE USING THIS PROGRAM, BACK UP ALL IMPORTANT SOFTWARE AND FILES, AND MOST OF ALL, READ THE MANUAL BEFORE PROCEEDING! AS I CANNOT RECOMPENCE FOR LOSSES. (INCLUDING, BUT NOT LIMITED TO LOSS OF BUSINESS, LOSS OF SOFTWARE/HARDWARE OR LOSS OF SANITY/HAIR).

    Introduction

The AmigaOS is an excellent operating system. Even the last OS before Commodore ran out of money (OS 3.1) can't be touched by Windoof and other operating systems. So why spoil it now? Commodore also brought in features such as Screen and Icon fonts, which could be proportional. And proportional fonts look so much nicer. So that is why I decided to have a bash at designing a nice looking text viewer to complement Workbench. Well, that is partly the reason. The other part is, I wanted to program... I was thinking about C, and then I just happened to see what E could do and I was hooked! So this is my grand contribution to the Amiga :).

    System requirements

Those requirements in red are essential for EvenMore to run, those in black are libraries used by EvenMore.

Kickstart 39+ 
Asl.library 37+ 
ReqTools.library 37+ 
XPK libraries 2+ 
Newicon.library 
Titlebar.image class

    Installation

Installation is simple. EvenMore should run directly from the directory it is in, without any need of setup if you have the required libraries already on your system, but if you don't, here is what to do.

1) Simply copy 'libs/reqtools.library' to 'Libs:', if you haven't already got it, or haven't got a version later than 37. 
2) Copy 'classes/images/titlebar.image' to 'SYS:classes/images/' 
3) Then copy the entire EvenMore directory anywhere on your harddrive or floppy disk. 
4) Run EvenMore, and configure the preferences to your own taste.

    Features

and more...

    Getting started

Arguments

EvenMore takes two arguments when running from Shell and just one when running from Workbench (Which is drawers or files).

    Shell

If you do not specify any filenames, a requester will pop up allowing you to do so. Once you have selected the file you wish to view, a window will open displaying the contents.

e.g. EvenMore S:User-startup PREFS=BigHD:EvenMore.prefs 
      EvenMore Docs:EvenMore S:User-startup S:Startup-sequence

    Workbench

You can either shift-select multiple files or drawers with EvenMore (Holding shift, left click on the EvenMore icon, then double click on a file), or if you simply double click on the EvenMore icon, a requester will allow you to choose a file. EvenMore of course supports drag and drop. Just drag a file or folder on to the EvenMore window, or onto the icon when EvenMore is iconified, and EvenMore will open the file or folder.


Interface

EvenMore will detect on start-up what type of files your have selected to open, if any. If you are running the FileTypes plugin module, EvenMore will first of all scan through what filetypes have been set up, and launch those specific applications with those files that have matched those in the filetypes.txt file. If you have selected a path, a requester will appear asking you to choose a file from the path you have selected.

The EvenMore window should then appear, and any files remaining to be opened will be opened now. You should have something like the picture below on the screen.

Close file Close currently displayed file
Open file Open a new file. If the file is already opened, the previously opened file will be viewed instead.
Reopen file Reopen displayed file
Quickload list Open a window to load a commonly accessed file
Save file Save displayed file in text format
Edit file Open the displayed file in a text editor
Print file Print the displayed file/highlighted section
Search window Search the document for words
Find last Repeat last search going backwards
Find next Repeat last search going forwards
Find occurance Find number of times a word occurs in the displayed file
Preferences Change the EvenMore settings

 

Across the top of the window you will see a toolbar, giving access to common functions of EvenMore. Positioning the mouse over each of these will display a help text to show what each button does. The buttons and an explanation of what they do are listed to the left...

 

 


Depending on the current configuration, you may have EvenMore set to open with a standard Amiga window, or on it's own custom window. Whatever the case may be, you can use the scroll bars available to scroll about the document. Pressing the HELP key will open a list of additional keys you may use to run common functions on EvenMore.

History Menu

Any files that are loaded into EvenMore are stored in memory. In fact, EvenMore will allow you to open up to 1000 files at the same time. Each filename is then added to the History menu. You can move between the files you have opened by selecting documents in this menu.

    Configuration

Clicking on the Preferences button on the main toolbar will bring up the settings window. Across the bottom of the window are 4 buttons, marked Load (Load a previously saved preference file), Save as (Save current settings under a new filename), Save (Save current configuration) and Ok (Accept current settings). 

 

 

Across the top, there are several tab headings. These are as follows...

Tab Setting Description
Appitem Position Using these two boxes, you can specify where on the screen the appitem will be created when EvenMore is iconified
Open/Close These two cycle gadgets will allow you to select how EvenMore behaves when it is opened or closed. It can open as an icon on Workbench, or when you quit, EvenMore can be iconified instead, etc.
Confirm quit A requester will appear whenever you want to quit, asking you to confirm this is ok.
Multiple copies If EvenMore is already running in the background when you try to open another file with EvenMore, the file will be passed on to the copy already open. This option disables that behaviour.
File/Compression XPK pack method If you have XPK archiver installed, you can select which method of arhiving you wish to use if you want to save a file crunched with XPK
XPK efficiency Again, same as above except this option specifies how efficient the crunch routine should be.
GUI/Border Border Using the listview, you can select what each GUI element that makes up the EvenMore interface will look like. 
Pens Clicking on each pen in the listview will allow you to select a colour for that pen
Offsets These are the gaps between the edge of the window and the rest of the interface, and the gap around the toolbar buttons in pixels.
Dither You can select a type of dither to use for either the window pen or the toolbar pen.
GUI/Gadgets Select icon set This is the path where EvenMore will find the images for the toolbar.
Position Where EvenMore will display the toolbar in the window.
GUI/Text Font Which font to use to display the file with.
Leading Extra space in pixels between lines in the file.
Tab How many characters a Tab will space on by (default is 8).
Page overlap How many lines will be `repeated` when you scroll by a page length.
Wheel-mouse Scroll How many lines a single scroll of a wheel mouse is equal to.
Smooth scroll Scrolling will be graduated instead of immediate.
Paths Default Document(s) loaded when EvenMore starts with no arguments.
Editor Path of your favourite text editor to use when editing files. Note that the string you enter here is basically a command line. So you can include options other than just the editor path.

Keyword... Replaced with...
%s  Full filename 
%l   Top line of file in the window

For exmaple...
EDITORSTR=c:ged "%s" LINE=%l

Printer Printer settings This page is self explanitry
Screen Mode Screen mode to use when using EvenMore's own screen.
Name Name of public screen EvenMore should create.
Use custom screens Whether or not to enable the use of EvenMore's own screen.
ASL filerequester Use an ASL filerequester instead of ReqTools (default).
Window Info bar The format of the file information bar. 
Keyword... Replaced with...

%fs   File size
%fl    First line in window
%ll    Last line in window
%tl    Total lines in document
%pg  Page
%cf   Current file viewed
%nf   Number of files open

Scrollers You can set which proportional gadgets should be available in the window, or have a borderless window for EvenMore.
3d window title If enable, when the window is borderless, the title will be drawn in 3d.

Quick Load

Clicking on the Quick Load icon on the main window will bring up a new window. You can store paths or files here that you view regularly, so that you can quickly view them without having to search through lots of drawers. The Open button will open the document you selected, the Add button will allow you to select a file to add to the list, and the Remove button will remove the selected document from the list. The Up and Down buttons will move the hilighted name up and down the list.

    Programming EvenMore

Arexx

You can use EvenMore's arexx port to control EvenMore remotely. The port's name is 'EvenMore', plus a number. This number will increment if a port of a similar name is found, for instance if you load two copies of EvenMore, the first copy will have a port name of 'EvenMore.1', and the second one will have a port name of 'EvenMore.2'. You can find which port EvenMore is using by looking in the Information/About requester.

The commands are:-

'r = ' indicates the command returns a value

CLOSE Close current file
CLOSEALL Close all files opened
r = GETFILENAME Return name of current file
r = GETFILESIZE Return size of current file
OPEN <name> Open a new file 
VIEWFILE <number> View a file already opened
r = CURRENTFILE Get number of current file displayed
SAVE <name> Save current file to disk
PRINT Print current file
r = GETLINE <number> Return text of line number
r = GETFIRSTLINE Get number of first line in window
r = GETLASTLINE Get number of last line in window
r = GETFIRSTCOL Same as above but for column numbers
r = GETLASTCOL Same as above but for column numbers
r = GETTOTALLINES Get total number of lines in window
r = GETTOTALCOLS Same as above but for columns
SCROLLTOLINE <number> Scroll to a line number in the window
SCROLLTOCOL <number> Same as above but for columns
SCROLLTOPAGE <number> Same as above but for pages
SCROLLTOPERCENT <percent> Same as above but for a percentage of the document
BOOKMARKSTORE <number 0-4> Store current position in document
BOOKMARKRECALL <number 0-4> Recall stored position in document
r = GETFONT Get the name and size of font used
SETFONT <name/size> Set the font in the window
r = SEARCH <string> Search for this string in the current document
r = OCCURANCE <string> Find how many times this string occurs in the document
GOTOSCREEN <name> Move window to another screen
ICONIFY Toggle iconifying of EvenMore
QUIT Close EvenMore

To use one of these commands from a shell, you could simply type the following:-

RX "ADDRESS 'EvenMore.1'; OPEN 's:startup-sequence "ram disk:my file"'"

Note the quotes which must be put around some strings when characters like ':' are present in them. If you do not specify a filename for OPEN (just '') or if you just specify a path, then a requester will open.

Plugins

A new feature is the ability to create plugins which greatly expand the potential functionality of EvenMore. These are fairly simple to code, and anyone with a basic understanding of any library-compiling language is able to create these. Some of the currently available plugins are the following (See the website for updates):-

Boing HTML2Text.plugin 1.02
Author: Chris Perver
Function: HTML documents converted to text with formatting

Boing Guide2Text.plugin 1.13
Author: Chris Perver
Function: AmigaGuide documents converted to text with formatting

Boing FileTypes 1.00
Author: Chris Perver
Function: A module to allow a primitive filetyping function using a textfile to determine which files are launched by which programs.

This plugin uses a file called 'filetypes.txt' to set up a primitive filetyping system. Simply edit it using Ed or some other text editor, and add additional lines for any filetypes your require. 

For example, to get EvenMore to pass any IFF pictures on to Multiview instead of trying to open them, I would enter the following line into filetypes.txt.

    #?.iff=sys:utilities/multiview "%s"

Again, this uses a simple wildcard system. Any files ending in .iff will be passed on to multiview. EvenMore automatically replaces "%s" with the name of the file you are trying to load.

Boing MSWord2Text.plugin 1.24
Author: Chris Perver
Function: Microsoft Word 95/2000 converted to text

Boing WordWorth2Text.plugin 1.00
Author: Chris Perver
Function: WordWorth documents converted to text. Tested on WordWorth 3.1se

Below is the template plugin file (AmigaE version) should you wish to write your own plugins for EvenMore. If you happen to write any plugins, drop me an email, and I can include the .plugin file in the EvenMore archive or on the webpage. All source will of course be copyrighted by yourself.


/*

This is a template plugin for EvenMore. The procedures MUST be 
kept in the same name in the same order as listed here.
You can add your own procedures, but these must be internal to this
plugin.

This layout may be subject to change!!!

When making your own plugin, change the LIBRARY name/version and the
description to your own names!

*/



OPT REG=5


MODULE `*epo`   
/* External module containing the plugin object. Currently, this contains...  */

OBJECT em_pluginobject
   filename:PTR TO CHAR                   /* filename of file to be opened */
   buffer:LONG                                        /* start address of file in memory */
   length                                                     /* length of file in memory */
   nbuffer:PTR TO LONG                     /* start of newly allocated memory for the file */
   nlength:LONG                                     /* length of newly allocated memory for the file */

   id:LONG                                               /* id of this plugin, not used yet */
ENDOBJECT

/* This OBJECT will be extended as necessary */


LIBRARY 'myplugin.plugin',1,1,'MyPlugin 1.0' IS em_main, em_end, em_info, em_pluginid, em_begin


/* STANDARD PROCS FOR PLUGINS */


/* CALLED TO RUN THE PLUGIN MODULE */

PROC em_begin(epo:PTR TO em_pluginobj)

/* This is used to test whether this plugin should be used on this file. If so,we will RETURN TRUE, otherwise FALSE. If we think the resulting file will be larger than the original, it is necessary to allocate a new memory area for it. In this case, return "MEM", <size of new file>. When EvenMore calls the em_main() PROC, your new memory will be epo.nbuffer and epo.nlength */

ENDPROC

PROC em_main(epo:PTR TO em_pluginobj)

/* This is your main procedure for the plugin. The epo object is an object which contains various variables passed on from EvenMore to your plugin */

/* In this procedure, if a file plugin, you should do some checks to see if the file is of the type you are looking for, and if not, make no modifications. Then RETURN TRUE OR FALSE depending whether your plugin has modified the file */
ENDPROC FALSE

/* NOT USED YET */

PROC em_end()      IS EMPTY

/* DESCRIPTION TEXT */

PROC em_info()     IS 'MyPlugin 1.0'

/* PLUGIN ID
   CURRENT LIST OF ID's
    "FILE"  -  Tells EvenMore this is a file type plugin to convert text
*/

PROC em_pluginid() IS "FILE"

/* NOT USED */

PROC main() IS EMPTY

    Contacting

You can contact me at the following addresses.

    Postal address:

    Chris Perver
    6 Gransha Road
    Bangor
    County Down
    N. Ireland
    BT20 4TG

Email: chris@evenmore.co.uk
URL: www.evenmore.co.uk
Telephone: 028 91 457144

I cannot expect to be able to develop this program much further, as I am a Christian and believe Jesus Christ will return very soon. If I do not reply to any mail for months and months, then the development of this program has ceased.

If anyone wishes to help in the distribution files, please email me. You could design a few NewIcons, MagicWB icons, Iconographics icons, plugins, or anything. If you have any suggestions or contributions for the distribution files, again email me :). Suggestions for the program are always welcome. Tell me what YOU would like to see in a text viewer.

    Credits

Me - Everything :) 
Mum & dad - RKRM manuals, Amiga 3000... (you name it, they provided it) 
Johan Bj�rnson - AmigaGuide, program icons... 
Per Reidar Verlo - Norsk Install script, locale translations 
Girish Nath - Program icons

Beta testers: 
Johan Bj�rnson 
Mikael Grahn 
Per Reidar Verlo 
Dominique Neveu 
Tony Hazel 
Andrew Holt 
Roland de Herder 
Raul Silva

Locale translators:
Per Reidar Verlo (prbverlo@online.no) - Norsk 
Roland de Herder (macron@multiweb.nl) - Nederlands 
Victor Guti�rrez (masone@ctv.es) - Espa�ol 
Jerome Chesnot (jchesnot@noname.fr) - Fran�ais
Raul Silva - Portugu�s
Vitaliy Chepeleff - Russian
Alfred Faust - Deutsch
Jan Zahurancik - Slovak

Without the following people, writing this program would have been virtually impossible...

Nico Fran�ois, Magnus Holmgren  - ReqTools 
Dietmar Eilert - GoldEd 
Wouter van Oortmerssen - AmigaE and EasyGUI 
J R Hulance - AmigaE and EasyGUI help

Ilan Sharoni - Word wrapping help 
Marco Talamelli - ReqTools help 
Eric Sauvageau - Screenmode help 
Victor Ducedre - dclistview EasyGUI plugin 
Ralph Wermke - register EasyGUI plugin 
Ali Graham - multitext EasyGUI plugin 
Sven Steiniger - patternStringF, runback modules 
Will Harwood - gadgetinfo module 
A.F.C. - rexxer, localer (www.intercom.it/~fsoft/afc.html) 
Massimo Tantignone - titlebarimage.class

If you are not listed here and you have helped me produce EvenMore, then I have probably just forgotten about you :). But don't fear, get in touch and let me know!